#ifndef _MISC_TR700_STM32_H_
#define _MISC_TR700_STM32_H_

struct dev_stm_info
{
    void *dev;
};


#define LS_CH_OFF   (0x00)
#define LS_CH_1     (0x01)
#define LS_CH_2     (0x02)
#define LS_CH_3     (0x03)

#define LS_MODE_CW  (0x00)
#define LS_MODE_270 (0x01)
#define LS_MODE_1K  (0x02)
#define LS_MODE_2K  (0x03)

#define OPM_R_CW    (0x00)
#define OPM_R_270   (0x01)
#define OPM_R_1K    (0x02)
#define OPM_R_2K    (0x03)

int tr700_stm_open(struct dev_stm_info *dsi);
int tr700_stm_close(struct dev_stm_info *dsi);

int tr700_ls_on(
	struct dev_stm_info *dsi,
	int                  nm,
	float                power_dBm,
	int                  mode);
int tr700_ls_off(
	struct dev_stm_info *dsi);
int tr700_opm_read(
	struct dev_stm_info *dsi,
	int                  nm,
	float                ref_dBm,
	float               *power_mW,
	float               *power_dBm,
	float               *power_ref);
int tr700_opm_getref(
	struct dev_stm_info *dsi,
	int                  nm,
	float               *power_dBm);
#endif
